package com.xiaoma.chat.domain;

import com.xiaoma.chat.vo.MessageRecordVo;

public class HistoryMessageRecord {

    private Integer id;
    private String appId;
    private String fromUserId;
    private String targetId;
    private Integer targetType;
    private String groupId;
    private String className;
    private byte[] content;
    private String dateTime;
    
    public Integer getId() {
        return id;
    }
    public void setId(Integer id) {
        this.id = id;
    }
    public String getAppId() {
        return appId;
    }
    public void setAppId(String appId) {
        this.appId = appId;
    }
    public String getFromUserId() {
        return fromUserId;
    }
    public void setFromUserId(String fromUserId) {
        this.fromUserId = fromUserId;
    }
    public String getTargetId() {
        return targetId;
    }
    public void setTargetId(String targetId) {
        this.targetId = targetId;
    }
    public Integer getTargetType() {
        return targetType;
    }
    public void setTargetType(Integer targetType) {
        this.targetType = targetType;
    }
    public String getGroupId() {
        return groupId;
    }
    public void setGroupId(String groupId) {
        this.groupId = groupId;
    }
    public String getClassName() {
        return className;
    }
    public void setClassName(String className) {
        this.className = className;
    }
    public byte[] getContent() {
        return content;
    }
    public void setContent(byte[] content) {
        this.content = content;
    }
    public String getDateTime() {
        return dateTime;
    }
    public void setDateTime(String dateTime) {
        this.dateTime = dateTime;
    }
    
    public MessageRecordVo build() {
        MessageRecordVo vo = new MessageRecordVo();
        vo.setId(this.id);
        vo.setAppId(this.appId);
        vo.setClassName(this.className);
        vo.setContent(new String(this.content));
        vo.setDateTime(this.dateTime);
        vo.setFromUserId(this.fromUserId);
        vo.setGroupId(this.groupId);
        vo.setTargetId(this.targetId);
        vo.setTargetType(this.targetType);
        return vo;
    }
}
